
gl path "~/Dropbox/voter_id/Replication"

cap log close

********************
****  Analysis  ****
********************

** Table 1
** descriptives on voter file, full file versus no dmv match
do "$path/table1.do"

** Figure 1 and Figure A2
** descriptives on reasons for provisional ballots by election
do "$path/figure1_and_a2.do"

** Figure 2
** DMV match status for those rejected for lack of ID
do "$path/figure2.do"

** Table 2
** Deterrent effect in the 2016 primary
do "$path/table2.do"

** Table 3
** Deterrent effect in the 2016 general
do "$path/table3.do"

** Table 4
** Deterrent effect in the 2018 primary
do "$path/table4.do"

** Table 5
** Deterrent effect in the 2018 general
do "$path/table5.do"

** Table 6
** Effect by race
do "$path/table6.do"

** Table 7 and Table A.10
** Vote Reduction decomposition
do "$path/table7_and_a10.do"


***********************
** Appendix Analyses **
***********************


** Figure A.1
** News coverage of the ID law (note: run this separately in R)
* "$path/figure_a1.R"

** Figure A.3
** binscatter of turnout to get a sense of pre-trending
do "$path/figure_a3.do"

** Table A.1
** check for pre-trending, primary
do "$path/table_a1.do"

** Table A.2 
** check for pre-trending, general
do "$path/table_a2.do"

** Table A.3
** effect in 2016 primary among those registered pre-2008
do "$path/table_a3.do"

** Table A.4
** effect in 2016 general among those registered pre-2008
do "$path/table_a4.do"

** Table A.5 and A.6
** Effect of ID law on 2016 primary turnout, by pre-treatment turnout
** exact match heterogeneity, primary
do "$path/table_a5.do"

** exact match heterogeneity, general
do "$path/table_a6.do"

** Table A.7
** Effect in 2016 primary, by race
do "$path/table_a7.do"

** Table A.8
** Effect in 2016 primary, by party
do "$path/table_a8.do"

** Table A.9
** Effect in 2016 general, by party
do "$path/table_a9.do"
